Skip to content

버튼 컴포넌트, 스토리북 개발 완료 내용 필독#24

Merged
Jieunsse merged 3 commits into
mainfrom
feature/button-v2
Feb 6, 2026
Merged

버튼 컴포넌트, 스토리북 개발 완료 내용 필독#24
Jieunsse merged 3 commits into
mainfrom
feature/button-v2

Conversation

@yooolleee

Copy link
Copy Markdown
Contributor

Summary

  1. feature/button 브랜치에서 개발을 했으나 테스트 페이지가 pr이 올라오면 안된다고 하여 브랜치를 새로파서 제외하고 올립니다.
    -> feature/button-v2 브랜치임 즉, feature/button는 없음

  2. 스토리북 업로드시 jsx 부분에서 벡틱이나 쌍따옴표 같은 코드를 직접 쓰는걸 eslint(eslint.config.mjs)에서 막고있습니다. 그래서 엔티티 코드 ", “, < 와 같은 코드로 입력을 하라고 error 문구가 나오는데 스토리북 같은 경우 저희는 테스트 페이지로써 사용하는 용도라 스토리북에 한해서 eslint 제한을 해제하고 올립니다. eslint.config.mjs 파일도 수정내역이 있습니다.

스크린샷 2026-02-04 165510

기타 컴포넌트에 대한 내용은 스토리북으로 확인 부탁드립니다.

Issue

  • Closes #

Scope

  • 포함

    • 변경한 내용
  • 특이사항

@yooolleee yooolleee added this to the 컴포넌트 milestone Feb 4, 2026
@yooolleee yooolleee self-assigned this Feb 4, 2026
@yooolleee yooolleee added the 기능추가 기능개발 및 추가할 때 사용해주세요. label Feb 4, 2026
@yooolleee yooolleee added this to workers Feb 4, 2026
@github-project-automation github-project-automation Bot moved this to 개발 대기중 in workers Feb 4, 2026
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @yooolleee, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

이 PR은 애플리케이션의 UI 일관성과 개발 효율성을 높이기 위해 포괄적인 버튼 컴포넌트 라이브러리를 도입합니다. 기본 버튼부터 특정 기능에 최적화된 버튼까지 다양한 유형을 제공하며, 각 컴포넌트는 Storybook을 통해 상세하게 문서화되어 있습니다. 또한, 개발 환경의 편의성을 위해 ESLint 설정이 조정되었고, 전역적인 스타일 관리를 위한 CSS 변수도 업데이트되었습니다.

Highlights

  • 버튼 컴포넌트 개발: 기본적인 BaseButton 컴포넌트와 함께 ArrowButton, DatePickerButton, EditButton, EnterButton, FilledRoundButton, FloatingButton, FloatingLikeButton, GnbAddButton, OutlineIconTextButton, ProgressButton 등 다양한 도메인별 버튼 컴포넌트가 새로 추가되었습니다.
  • 스토리북 통합 및 문서화: 새로 추가된 모든 버튼 컴포넌트에 대해 상세한 스토리북 문서가 작성되었습니다. 각 스토리에는 다양한 사용 예시, 접근성 테스트, 상호작용 상태, 크기 사양 등이 포함되어 있습니다.
  • ESLint 설정 업데이트: 스토리북 파일(**/*.stories.@(ts|tsx), **/*.mdx)에서 JSX 내 백틱이나 쌍따옴표 사용 시 발생하는 react/no-unescaped-entities ESLint 오류를 해결하기 위해 해당 규칙이 비활성화되었습니다.
  • CSS 변수 및 전역 스타일 개선: --color-background-primary 변수 값이 변경되었고, danger 상태 버튼의 hoverpressed 상태를 위한 새로운 CSS 변수(--color-status-danger-hover, --color-status-danger-pressed)가 추가되었습니다. 또한, color.css 파일이 Storybook 및 메인 레이아웃에 전역적으로 임포트되어 일관된 스타일 적용을 보장합니다.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • .storybook/preview.ts
    • 전역 color.css 스타일시트 임포트 추가
  • eslint.config.mjs
    • 스토리북 파일에 대해 react/no-unescaped-entities ESLint 규칙 비활성화
  • src/app/layout.tsx
    • 전역 color.css 스타일시트 임포트 추가
  • src/components/Button/base/BaseButton.module.css
    • 새로운 기본 버튼 스타일 정의 (크기, 변형, 상태)
  • src/components/Button/base/BaseButton.stories.tsx
    • BaseButton 컴포넌트의 스토리북 문서 추가 (다양한 상태 및 사용 예시)
  • src/components/Button/base/BaseButton.tsx
    • BaseButton 컴포넌트 구현 (variant, size, type, disabled props 지원)
  • src/components/Button/base/index.ts
    • BaseButton 컴포넌트 및 관련 타입 내보내기
  • src/components/Button/domain/ArrowButton/ArrowButton.module.css
    • ArrowButton 컴포넌트 스타일 정의 (방향, 크기, 상호작용)
  • src/components/Button/domain/ArrowButton/ArrowButton.stories.tsx
    • ArrowButton 컴포넌트의 스토리북 문서 추가 (캐러셀, 달력 예시 포함)
  • src/components/Button/domain/ArrowButton/ArrowButton.tsx
    • ArrowButton 컴포넌트 구현 (방향, 크기, 클릭 핸들러, disabled props 지원)
  • src/components/Button/domain/DatePickerButton/DatePickerButton.module.css
    • DatePickerButton 컴포넌트 스타일 정의 (선택됨, hover, active, focus, disabled 상태)
  • src/components/Button/domain/DatePickerButton/DatePickerButton.stories.tsx
    • DatePickerButton 컴포넌트의 스토리북 문서 추가 (요일 선택기 예시 포함)
  • src/components/Button/domain/DatePickerButton/DatePickerButton.tsx
    • DatePickerButton 컴포넌트 구현 (요일, 라벨, 선택 상태, 클릭 핸들러, disabled props 지원)
  • src/components/Button/domain/EditButton/EditButton.module.css
    • EditButton 컴포넌트 스타일 정의 (크기, 상호작용)
  • src/components/Button/domain/EditButton/EditButton.stories.tsx
    • EditButton 컴포넌트의 스토리북 문서 추가 (프로필/썸네일 편집 예시 포함)
  • src/components/Button/domain/EditButton/EditButton.tsx
    • EditButton 컴포넌트 구현 (크기, 클릭 핸들러, disabled props 지원)
  • src/components/Button/domain/EnterButton/EnterButton.module.css
    • EnterButton 컴포넌트 스타일 정의 (활성화/비활성화 상태, 상호작용)
  • src/components/Button/domain/EnterButton/EnterButton.stories.tsx
    • EnterButton 컴포넌트의 스토리북 문서 추가 (댓글/채팅 입력, 검색 예시 포함)
  • src/components/Button/domain/EnterButton/EnterButton.tsx
    • EnterButton 컴포넌트 구현 (클릭 핸들러, active props 지원)
  • src/components/Button/domain/FilledRoundButton/FilledRoundButton.module.css
    • FilledRoundButton 컴포넌트 스타일 정의 (외형, 그림자, 아이콘/라벨)
  • src/components/Button/domain/FilledRoundButton/FilledRoundButton.stories.tsx
    • FilledRoundButton 컴포넌트의 스토리북 문서 추가 (CTA, 완료 확인, 모달 액션 예시 포함)
  • src/components/Button/domain/FilledRoundButton/FilledRoundButton.tsx
    • FilledRoundButton 컴포넌트 구현 (appearance, shadow, type, children props 지원)
  • src/components/Button/domain/FilledRoundButton/index.ts
    • FilledRoundButton 컴포넌트 내보내기
  • src/components/Button/domain/FloatingButton/FloatingButton.module.css
    • FloatingButton 컴포넌트 스타일 정의 (크기, 원형, 그림자, 상호작용)
  • src/components/Button/domain/FloatingButton/FloatingButton.stories.tsx
    • FloatingButton 컴포넌트의 스토리북 문서 추가 (게시판, 할일 목록, 편집 모드 예시 포함)
  • src/components/Button/domain/FloatingButton/FloatingButton.tsx
    • FloatingButton 컴포넌트 구현 (아이콘 타입, 클릭 핸들러, disabled props 지원)
  • src/components/Button/domain/FloatingButton/FloatingLikeButton.module.css
    • FloatingLikeButton 컴포넌트 스타일 정의 (원형, 그림자, 카운트 표시, 상호작용)
  • src/components/Button/domain/FloatingButton/FloatingLikeButton.stories.tsx
    • FloatingLikeButton 컴포넌트의 스토리북 문서 추가 (좋아요 토글, 게시글, 갤러리 예시 포함)
  • src/components/Button/domain/FloatingButton/FloatingLikeButton.tsx
    • FloatingLikeButton 컴포넌트 구현 (좋아요 상태, 카운트, 토글 핸들러, disabled props 지원)
  • src/components/Button/domain/GnbAddButton/GnbAddButton.module.css
    • GnbAddButton 컴포넌트 스타일 정의 (전체 너비, 아이콘, 텍스트)
  • src/components/Button/domain/GnbAddButton/GnbAddButton.stories.tsx
    • GnbAddButton 컴포넌트의 스토리북 문서 추가 (GNB 사이드바, 프로젝트 사이드바 예시 포함)
  • src/components/Button/domain/GnbAddButton/GnbAddButton.tsx
    • GnbAddButton 컴포넌트 구현 (라벨, 클릭 핸들러, disabled props 지원)
  • src/components/Button/domain/OutlineIconTextButton/OutlineIconTextButton.module.css
    • OutlineIconTextButton 컴포넌트 스타일 정의 (상태별 아이콘 변경, 텍스트/테두리)
  • src/components/Button/domain/OutlineIconTextButton/OutlineIconTextButton.stories.tsx
    • OutlineIconTextButton 컴포넌트의 스토리북 문서 추가 (할일 완료, 작업 승인, 폼 제출 예시 포함)
  • src/components/Button/domain/OutlineIconTextButton/OutlineIconTextButton.tsx
    • OutlineIconTextButton 컴포넌트 구현 (아이콘과 텍스트 결합, CSS로 상태별 아이콘 제어)
  • src/components/Button/domain/OutlineIconTextButton/index.ts
    • OutlineIconTextButton 컴포넌트 내보내기
  • src/components/Button/domain/ProgressButton/ProgressButton.module.css
    • ProgressButton 컴포넌트 스타일 정의 (전체 너비, 텍스트 말줄임, 아이콘)
  • src/components/Button/domain/ProgressButton/ProgressButton.stories.tsx
    • ProgressButton 컴포넌트의 스토리북 문서 추가 (칸반 보드, 모바일 뷰 예시 포함)
  • src/components/Button/domain/ProgressButton/ProgressButton.tsx
    • ProgressButton 컴포넌트 구현 (라벨, 클릭 핸들러, disabled props 지원)
  • src/components/Button/shared/ButtonBehavior.module.css
    • 모든 버튼 컴포넌트가 공유하는 기본 동작 및 리셋 스타일 정의
  • src/shared/styles/color.css
    • --color-background-primary 값을 #0f172a에서 #ffffff로 변경
    • --color-status-danger-hover--color-status-danger-pressed 변수 추가
Activity
  • yooolleee 님이 feature/button 브랜치에서 테스트 페이지를 제외하고 feature/button-v2 브랜치를 새로 생성하여 PR을 올렸습니다.
  • ESLint 설정(eslint.config.mjs)에서 Storybook 파일 내 JSX 백틱/쌍따옴표 사용을 허용하도록 react/no-unescaped-entities 규칙을 비활성화했습니다.
  • PR 설명에 ESLint 오류 관련 스크린샷이 첨부되었습니다.
  • 컴포넌트 상세 내용은 스토리북을 통해 확인해달라는 요청이 있었습니다.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

전반적으로 버튼 컴포넌트와 스토리북이 체계적으로 잘 구성되었습니다. 특히 스토리북 문서화가 매우 상세하여 컴포넌트의 사용법을 이해하기 쉽습니다. 몇 가지 개선점을 제안드립니다.

  • AllVariantsDisabled 스토리에서 disabled prop이 누락된 부분이 있습니다.
  • EditButtonProgressButton의 CSS에서 색상 값이 하드코딩되어 있거나 정의되지 않은 변수를 사용하여 유지보수성을 해칠 수 있습니다. 디자인 시스템의 색상 변수를 사용하거나 새로운 변수를 추가하는 것을 권장합니다.
  • EnterButtonaria-label을 더 범용적으로 만들면 재사용성이 향상될 것입니다.

}

.button:hover {
background: var(--color-border-secondary);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

:hover 상태에서 정의되지 않은 --color-border-secondary CSS 변수를 사용하고 있습니다. color.css에 정의된 변수로 교체하거나, 필요한 경우 새 변수를 정의해주세요.

@yooolleee yooolleee Feb 6, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

코드 지웠습니다

Comment on lines +340 to +342
<BaseButton size="small" variant="danger">
Danger
</BaseButton>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

AllVariantsDisabled 스토리에서 small 사이즈 danger 버튼에 disabled prop이 누락되었습니다. 다른 버튼들과 일관성을 맞추고 스토리의 의도를 명확히 하기 위해 disabled prop을 추가하는 것이 좋습니다.

Suggested change
<BaseButton size="small" variant="danger">
Danger
</BaseButton>
<BaseButton size="small" variant="danger" disabled>
Danger
</BaseButton>

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

“prop 누락” 지적은 버전·의도 차이에서 나오는 리뷰 성격이지, 버그나 결함은 아니라서 기능·설계·품질 관점에서는 문제없습니다


.button:active {
transform: scale(0.95);
background: #b0bcc9;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

:active 상태의 배경색으로 #b0bcc9가 하드코딩되어 있습니다. 유지보수성과 일관성을 위해 color.css에 정의된 디자인 시스템의 색상 변수를 사용하는 것을 권장합니다.

Suggested change
background: #b0bcc9;
background: var(--color-interaction-inactive);

@yooolleee yooolleee Feb 6, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

코드 지웠습니다

className={styles.button}
onClick={onClick}
disabled={!active} // active가 false면 자동으로 disabled
aria-label="댓글 등록"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

aria-label이 "댓글 등록"으로 하드코딩되어 있습니다. 이 버튼이 스토리북의 예시처럼 댓글 외에 채팅 메시지 전송, 검색 등 다양한 맥락에서 사용될 수 있으므로, "전송"과 같이 더 범용적인 용어를 사용하거나 aria-label을 prop으로 받아 유연하게 설정할 수 있도록 변경하는 것을 고려해보세요.

Suggested change
aria-label="댓글 등록"
aria-label="전송"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

댓글 등록에 사용하는 도메인 맥락의 컴포넌트라 의미를 범용적으로 적기보다 더 명시적으로 적었지만 고쳐도 문제 안될 것 같아서 고쳐놨습니다.

}

.button:hover:not(:disabled) {
background: #cbd5e1;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

:hover 상태의 배경색으로 #cbd5e1이 하드코딩되어 있습니다. 유지보수성과 일관성을 위해 color.css에 정의된 디자인 시스템의 색상 변수를 사용하는 것을 권장합니다. 예를 들어, --color-interaction-inactive를 사용하거나 더 적절한 새 변수를 추가할 수 있습니다.

Suggested change
background: #cbd5e1;
background: var(--color-interaction-inactive);

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

코드 지웠습니다

@Jieunsse Jieunsse merged commit 38124ed into main Feb 6, 2026
1 check passed
@github-project-automation github-project-automation Bot moved this from 개발 대기중 to 개발 완료 in workers Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

기능추가 기능개발 및 추가할 때 사용해주세요.

Projects

Status: 개발 완료

Development

Successfully merging this pull request may close these issues.

2 participants